<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>PWA 响应策略示例</title>
  <link rel="stylesheet" href="./index.1236d1250f7ffbdc.css">
</head>
<body>
  <h1 id="title"></h1>
  <div id="content"></div>
  <div class="bottom">当前访问量：<span id="count"></span></div>
  <script>
    if ('serviceWorker' in navigator) {
      window.addEventListener('load', function() {
        navigator.serviceWorker.register('/sw.js').then(function(registration) {
          // 注册成功
          console.log('Service Worker 注册成功！')
        }).catch(function(err) {
          // 注册失败 :(
          console.log('Service Worker 注册失败！');
        });
      });
    }
  </script>
  <script src="./index.f8666b443c7a0e84.js"></script>
</body>
</html>
